home *** CD-ROM | disk | FTP | other *** search
- % -----------------------------------------------------------------------------
- % Keyboard demonstration script *TERMINATE PRESCRIPTION*
- % -----------------------------------------------------------------------------
- %
- % Version : 1.00
- % Filename : SHOWKEY.TSL
- % Company : None
- % Programmer : Dave Wapstra & Bo Bendtsen
- % Module created : 07 Aug 1995
- % Latest revision : 09 Aug 1995
- % Language/version : Terminate Prescription 1.00
- % Remarks : Demonstrates keyboard functions
- %
- % -----------------------------------------------------------------------------
-
- Window 1,1,30,15,6,0,23,23,27," ShowKey "
- WriteAStr 2,0,23," Esc to Abort "
-
- Set Key=0
- Repeat
- If AltPressed=1
- WriteAStr 2,14,23+128," Alt "
- Else
- WriteAStr 2,14,23,"─────"
- Endif
- If CtrlPressed=1
- WriteAStr 9,14,23+128," Ctrl "
- Else
- WriteAStr 9,14,23,"──────"
- Endif
- If ShiftPressed=1
- WriteAStr 16,14,23+128," Shift "
- Else
- WriteAStr 16,14,23,"───────"
- Endif
- If Keypressed=1
- Set Key=GetKey
- SetAttr 23
- Println BlankBefore(Key,4)," ",WordToHex(Key)
- Endif
- Until Key = 27
-
- RemoveWindow
-
-